package com.hucsmn.phone;

/**
 * 抽象套餐测试类。
 */
public class PlanTest extends Tester {
    public static void main(String[] args) {
        Plan cp = new CallPlan(200.0, 100, 20.0);
        Plan tp = new TrafficPlan(1024, 2.0);

        asserts(cp.getCost() == 20.0);
        asserts(tp.getCost() == 2.0);

        cp.setCost(30.0);
        tp.setCost(5.0);

        asserts(cp.getCost() == 30.0);
        asserts(tp.getCost() == 5.0);
    }
}
